.vessel-extraction-viewer {
  display: flex;
  flex-direction: column;
  height: 100vh;
  background: #0d1117;
  color: #f0f6fc;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Noto Sans', Helvetica, Arial, sans-serif;
}

.vessel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background: #21262d;
  border-bottom: 1px solid #30363d;
  flex-shrink: 0;
}

.vessel-header h3 {
  margin: 0;
  color: #f0f6fc;
  font-size: 16px;
  font-weight: 600;
}

.exit-vessel-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  background: #f85149;
  border: 1px solid #da3633;
  border-radius: 6px;
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.exit-vessel-btn:hover {
  background: #da3633;
  border-color: #b62324;
  transform: translateY(-1px);
}

.exit-icon {
  font-size: 16px;
  font-weight: bold;
}

.exit-text {
  font-size: 13px;
}

.vessel-content {
  display: flex;
  flex: 1;
  min-height: 0;
}

/* 左侧图像面板 */
.vessel-image-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
  border-right: 1px solid #30363d;
  min-width: 0;
}

.vessel-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  background: #21262d;
  border-bottom: 1px solid #30363d;
  flex-shrink: 0;
}

.tool-btn {
  padding: 6px 12px;
  background: #21262d;
  border: 1px solid #30363d;
  border-radius: 4px;
  color: #f0f6fc;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.tool-btn:hover {
  background: #30363d;
  border-color: #484f58;
}

.vessel-info {
  font-size: 12px;
  color: #8b949e;
  font-weight: 500;
}

.canvas-container {
  flex: 1;
  position: relative;
  overflow: hidden;
  background: #0d1117;
}

.vessel-canvas,
.vessel-overlay-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  cursor: grab;
}

.vessel-canvas:active,
.vessel-overlay-canvas:active {
  cursor: grabbing;
}

/* 右侧控制面板 */
.vessel-control-panel {
  width: 320px;
  flex-shrink: 0;
  background: #161b22;
  display: flex;
  flex-direction: column;
}

.control-header {
  padding: 12px 16px;
  background: #21262d;
  border-bottom: 1px solid #30363d;
}

.control-header h4 {
  margin: 0;
  color: #f0f6fc;
  font-size: 14px;
  font-weight: 600;
}

.control-content {
  padding: 16px;
  overflow-y: auto;
  flex: 1;
}

/* 阈值控制 */
.threshold-control {
  margin-bottom: 24px;
}

.threshold-control label {
  display: block;
  margin-bottom: 8px;
  color: #f0f6fc;
  font-size: 13px;
  font-weight: 500;
}

.threshold-slider-container {
  display: flex;
  align-items: center;
  gap: 12px;
}

.threshold-slider {
  flex: 1;
  height: 6px;
  background: #30363d;
  border-radius: 3px;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

.threshold-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  background: #238636;
  border-radius: 50%;
  cursor: pointer;
  border: 2px solid #0d1117;
  box-shadow: 0 0 0 1px #30363d;
}

.threshold-slider::-moz-range-thumb {
  width: 18px;
  height: 18px;
  background: #238636;
  border-radius: 50%;
  cursor: pointer;
  border: 2px solid #0d1117;
  box-shadow: 0 0 0 1px #30363d;
}

.threshold-value {
  font-size: 13px;
  font-weight: 600;
  color: #238636;
  min-width: 40px;
  text-align: center;
}

/* 快速设置按钮 */
.threshold-presets {
  margin-bottom: 24px;
}

.threshold-presets label {
  display: block;
  margin-bottom: 8px;
  color: #f0f6fc;
  font-size: 13px;
  font-weight: 500;
}

.preset-buttons {
  display: flex;
  gap: 8px;
}

.preset-btn {
  flex: 1;
  padding: 6px 8px;
  background: #21262d;
  border: 1px solid #30363d;
  border-radius: 4px;
  color: #f0f6fc;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.preset-btn:hover {
  background: #30363d;
  border-color: #484f58;
}

.preset-btn:active {
  background: #238636;
  border-color: #2ea043;
}

/* 分割统计信息 */
.mask-info {
  margin-bottom: 24px;
  padding: 12px;
  background: #21262d;
  border-radius: 6px;
  border: 1px solid #30363d;
}

.mask-info h5 {
  margin: 0 0 12px 0;
  color: #f0f6fc;
  font-size: 13px;
  font-weight: 600;
}

.info-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
  font-size: 12px;
}

.info-item:last-child {
  margin-bottom: 0;
}

.info-item span:first-child {
  color: #8b949e;
}

.info-item span:last-child {
  color: #f0f6fc;
  font-weight: 500;
}

/* Mask操作按钮 */
.mask-actions {
  margin-top: auto;
}

.generate-mask-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 12px 16px;
  background: linear-gradient(135deg, #238636, #2ea043);
  border: 1px solid #46954a;
  border-radius: 6px;
  color: #f0f6fc;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-bottom: 12px;
}

.generate-mask-btn:hover:not(:disabled) {
  background: linear-gradient(135deg, #2ea043, #46954a);
  border-color: #56ab5a;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(35, 134, 54, 0.3);
}

.generate-mask-btn:disabled {
  background: #30363d;
  border-color: #484f58;
  color: #8b949e;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-icon {
  font-size: 16px;
}

.btn-text {
  font-weight: 600;
}

.mask-description {
  font-size: 11px;
  color: #8b949e;
  text-align: center;
  line-height: 1.4;
}

/* 响应式设计 */
@media (max-width: 1024px) {
  .vessel-control-panel {
    width: 280px;
  }
  
  .control-content {
    padding: 12px;
  }
}

@media (max-width: 768px) {
  .vessel-content {
    flex-direction: column;
  }
  
  .vessel-image-panel {
    border-right: none;
    border-bottom: 1px solid #30363d;
    flex: 1;
    min-height: 300px;
  }
  
  .vessel-control-panel {
    width: 100%;
    flex: none;
    height: 250px;
  }
  
  .threshold-presets .preset-buttons {
    flex-wrap: wrap;
  }
  
  .preset-btn {
    min-width: 60px;
  }
} 